<%@ page language="java" pageEncoding="UTF-8"%>



<div class="control-group">
	<table>
		<thead>
			<th width="15%">编号</th>
			<th width="15%">地点名称</th>
			<th width="15%">行政区</th>
			<th width="15%">商区</th>
			<th width="10%">取餐开始时间</th>
			<th width="10%">取餐截止时间</th>
			<th width="10%">状态</th>
			<th width="10%">顺序</th>
			<th width="10%">操作</th>
		</thead>
		<tbody id="zone_place_list">
			<tr>
				<td width="15%">td1</td>
				<td width="15%">td2</td>
				<td width="15%">td3</td>
				<td width="15%">td4</td>
				<td width="10%">td5</td>
				<td width="10%">td6</td>
				<td width="10%">td7</td>
				<td width="10%">td8</td>
				<td width="10%">td9</td>
			</tr>
		</tbody>
	</table>
	<button id="new_zone_place" type="button" onclick="newzoneplace();" class="btn btn-primary" data-toggle="button">新建</button>
</div>

<script type="text/javascript">
function newzoneplace()
{
	var re = window.showModalDialog("zone/zone-place-new.do");
	_place_refresh();
}

require.config({		    
    'baseUrl': './asset'
});
require(['admin-zone-place'], function(zoneplace) {
	zoneplace.init();
});

function _place_mod(zoneid)
{
	window.showModalDialog("zone/zone-place-mod.do?zoneid="+zoneid);
	_place_refresh();
}

function _place_refresh()
{
	require(['admin-zone-place'], function(zoneplace) {
		zoneplace.init();
	});
}

function _place_del(zoneid)
{
	if(confirm("是否删除"))
	{
		var xmlhttp=new XMLHttpRequest();
		
		xmlhttp.open("GET","zone/zone-place-del.do?zoneid="+zoneid,true);
		xmlhttp.send();
		alert("删除成功");
	}
	_place_refresh();
}
</script>